/*
 * An XML document type.
 * Localname: EObject
 * Namespace: http://www.eclipse.org/emf/2002/Ecore
 * Java type: org.eclipse.emf.x2002.ecore.EObjectDocument
 *
 * Automatically generated - do not modify.
 */
package org.eclipse.emf.x2002.ecore.impl;
/**
 * A document containing one EObject(@http://www.eclipse.org/emf/2002/Ecore) element.
 *
 * This is a complex type.
 */
public class EObjectDocumentImpl extends org.apache.xmlbeans.impl.values.XmlComplexContentImpl implements org.eclipse.emf.x2002.ecore.EObjectDocument
{
    private static final long serialVersionUID = 1L;
    
    public EObjectDocumentImpl(org.apache.xmlbeans.SchemaType sType)
    {
        super(sType);
    }
    
    private static final javax.xml.namespace.QName EOBJECT$0 = 
        new javax.xml.namespace.QName("http://www.eclipse.org/emf/2002/Ecore", "EObject");
    
    
    /**
     * Gets the "EObject" element
     */
    public org.apache.xmlbeans.XmlObject getEObject()
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.XmlObject target = null;
            target = (org.apache.xmlbeans.XmlObject)get_store().find_element_user(EOBJECT$0, 0);
            if (target == null)
            {
                return null;
            }
            return target;
        }
    }
    
    /**
     * Sets the "EObject" element
     */
    public void setEObject(org.apache.xmlbeans.XmlObject eObject)
    {
        generatedSetterHelperImpl(eObject, EOBJECT$0, 0, org.apache.xmlbeans.impl.values.XmlObjectBase.KIND_SETTERHELPER_SINGLETON);
    }
    
    /**
     * Appends and returns a new empty "EObject" element
     */
    public org.apache.xmlbeans.XmlObject addNewEObject()
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.XmlObject target = null;
            target = (org.apache.xmlbeans.XmlObject)get_store().add_element_user(EOBJECT$0);
            return target;
        }
    }
}
